package com.sys.SysLogs.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.sys.common.annotation.Excel;
import com.sys.common.core.domain.BaseEntity;

/**
 * 订单操作日志对象 sys_sales_order_logs
 * 
 * @author ruoyi
 * @date 2025-09-28
 */
public class SysSalesOrderLogs extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 日志ID（主键） */
    private Long logId;

    /** 关联的订单ID */
    @Excel(name = "关联的订单ID")
    private Long orderId;

    /** 变更前的状态​​ */
    @Excel(name = "变更前的状态​​")
    private String oldStatus;

    /** 变更后的状态 */
    @Excel(name = "变更后的状态")
    private String newStatus;

    /** 操作人（sys_user.user_id） */
    @Excel(name = "操作人", readConverterExp = "s=ys_user.user_id")
    private Long operatorId;

    /** 变更原因（如取消原因） */
    @Excel(name = "变更原因", readConverterExp = "如=取消原因")
    private String changeReason;

    /** 操作时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "操作时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createdAt;

    public void setLogId(Long logId) 
    {
        this.logId = logId;
    }

    public Long getLogId() 
    {
        return logId;
    }

    public void setOrderId(Long orderId) 
    {
        this.orderId = orderId;
    }

    public Long getOrderId() 
    {
        return orderId;
    }

    public void setOldStatus(String oldStatus) 
    {
        this.oldStatus = oldStatus;
    }

    public String getOldStatus() 
    {
        return oldStatus;
    }

    public void setNewStatus(String newStatus) 
    {
        this.newStatus = newStatus;
    }

    public String getNewStatus() 
    {
        return newStatus;
    }

    public void setOperatorId(Long operatorId) 
    {
        this.operatorId = operatorId;
    }

    public Long getOperatorId() 
    {
        return operatorId;
    }

    public void setChangeReason(String changeReason) 
    {
        this.changeReason = changeReason;
    }

    public String getChangeReason() 
    {
        return changeReason;
    }

    public void setCreatedAt(Date createdAt) 
    {
        this.createdAt = createdAt;
    }

    public Date getCreatedAt() 
    {
        return createdAt;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("logId", getLogId())
            .append("orderId", getOrderId())
            .append("oldStatus", getOldStatus())
            .append("newStatus", getNewStatus())
            .append("operatorId", getOperatorId())
            .append("changeReason", getChangeReason())
            .append("createdAt", getCreatedAt())
            .toString();
    }
}
